<?php
// +----------------------------------------------------------------------
// | sfadmin - Suifeng Administration
// +----------------------------------------------------------------------
// | Copyright (c) 2017-2020 http://suifeng.tech All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: suifeng <1787585212@qq.com>
// +----------------------------------------------------------------------

namespace app\shop\model;

use suifeng\Model;

class Category extends Model
{
    /**
     * 数据表名。
     *
     * @var string
     */
    protected $name = 'shop_category';

    /**
     * 获取列表。
     *
     * @param array $params
     * @return unknown
     */
    public function retrieve_list($pagination)
    {
//         $where_map = isset($pagination['where_map']) ? $pagination['where_map'] null;
//         $page_num = isset($pagination['page_num']) ? intval($pagination['page_num']) : 1;
//         $page_size = isset($pagination['page_size']) ? intval($pagination['page_size']) : 1;
//         $sort_field = isset($pagination['sort_field']) ? intval($pagination['page_size']) : 1;
//         $sort_order = isset($pagination['sort_order']) ? intval($pagination['page_size']) : 1;

        return null;
    }

    /**
     * 获取列表。
     *
     * @param array $params
     * @return unknown
     */
    public function retrieve_count($where)
    {
        return $this->where($where)->count();
    }
}
